#include <iostream>

using namespace std;

class NOShuXing {
    public:
        int i;
        char b;
        virtual void  show(){cout << "NoShuXing is me." << endl;}
        ~NOShuXing(){cout << "distory NOShuXing" << endl;}
};

class SubClass: public NOShuXing {
    public:
        char c;
        static int n;
        void show(){}
        ~SubClass(){cout << "distory SubClass" << endl;}
};

int SubClass::n = 100;

class NOShuXingWithAVirt {
    public:
        void show(){cout << "NoShuXingWithAVirt is me." << endl;}
        //virtual void setData(){cout << "Set Data." << endl;}
};



int main(int argc, const char *argv[])
{
    cout << "the memory size of NoShuXing:" << sizeof(NOShuXing) << endl;   
    cout << "the memory size of NoShuXingWithAVirt:" << sizeof(NOShuXingWithAVirt) << endl;   
    cout << "the memory size of SubClass:" << sizeof(SubClass) << endl;
    SubClass *s1 = new SubClass;
    NOShuXing *p1 = s1;
    delete s1;
    return 0;
}
